package org.resotc.model;

import java.util.HashMap;
import java.util.List;

public interface Centroid extends Element {
	
	/**
	 * Returns the id of a specific centroid.
	 */
	public int getId();
	
	/**
	 * Returns the number of the creation-pattern.
	 * @return
	 */
	public int getCreationPattern();
	
	/**
	 * Returns the x-coordinate.
	 */
	public double getX();
	
	/**
	 * Returns the y-coordinate
	 */
	public double getY();
	
	/**
	 * Sets the x-coordinate.
	 */
	public void setX(double x);
	
	/**
	 * Sets the y-coordinate.
	 */
	public void setY(double y);
	
	public List<?> generateTrafficPerStep();

	public void addArrivingIndividual(Individual ind);

	public void initializeQueues(HashMap<Integer, Queue> queues);

	public HashMap<Integer, Queue> getQueues();

	/**
	 * Puts a neighbour depending on it's type (Centroid or Intersection) into a
	 * HashMap.
	 * 
	 * @param or
	 * @param neighbour
	 * @param linkToNeighbour
	 */
	public void addNeighbour(NeighbourOrientation or, Element neighbour,
			Element linkToNeighbour);

	/**
	 * Method is updating a existing neighbour.
	 * 
	 * @param or
	 * @param neighbour
	 * @param linkToNeighbour
	 */
	public void updateNeighbour(NeighbourOrientation or, Element neighbour,
			Element linkToNeighbour);

	/**
	 * Adds or updates a neighbour. This method is mainly used due to the
	 * methods addNeighbour and updateNeighbour.
	 * 
	 * @param or
	 * @param neighbour
	 * @param linkToNeighbour
	 */
	public void addAndUpdateNeighbour(NeighbourOrientation or,
			Element neighbour, Element linkToNeighbour);

	/**
	 * Returns neighbours of the centroid.
	 * 
	 * @return
	 */
	public HashMap<NeighbourOrientation, Element> getNeighbours();

	public int getIndividualPerHour();

	public void setIndividualPerHour(int individualPerHour);

	/**
	 * Get the Mode of individual creation
	 * 
	 * @param mode
	 */
	public String getMode();

	/**
	 * Set the Mode of individual creation
	 * 
	 * @param mode
	 */
	public void setMode(String mode);
}
